package com.jeff.tianti.org.dao;

import com.jeff.tianti.common.dao.CommonDao;
import com.jeff.tianti.org.entity.Dictionary;
import com.jeff.tianti.org.entity.Role;
import org.hibernate.annotations.SQLUpdate;
import org.jboss.logging.annotations.Param;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;

import java.util.List;

public interface DictionaryDao extends DictionaryCustomDao, CommonDao<Dictionary, String> {
    @Query("from Dictionary d where d.code = ?1 and d.id <> ?2")
    List<Dictionary> findByCode(String code,String id);

    @Query("update Dictionary d set d.deleteFlag=?1 where d.id=?2")
   void updateDelFlag(String delFlag, String id);


}
